package com.pkk.spring.cloud.starter.gateway.annotation;

import com.pkk.spring.cloud.service.gateway.annotation.RouteDefinitionRepositoryAdviceModel;
import com.pkk.spring.cloud.service.gateway.selector.RouteDefinitionRepositoryImportSelector;
import java.lang.annotation.Documented;
import java.lang.annotation.ElementType;
import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;
import java.lang.annotation.Target;
import org.springframework.context.annotation.Import;

/**
 * 启用动态路由
 *
 * @author peikunkun
 * @version V1.0
 * @date 2021-01-14 14:06
 **/
@Documented
@Target(ElementType.TYPE)
@Retention(RetentionPolicy.RUNTIME)
@Import({RouteDefinitionRepositoryImportSelector.class})
public @interface EnableDynamicRoute {


  /**
   * 持久层路由的模式选择
   * 默认为:REDIS
   *
   * @return com.pkk.spring.cloud.service.gateway.annotation.RouteDefinitionRepositoryAdviceModel
   * @Param
   * @author peikunkun
   * @date 2021/1/15 0015 下午 5:45
   * @since
   */
  RouteDefinitionRepositoryAdviceModel mode() default RouteDefinitionRepositoryAdviceModel.NONE;


}
